home *** CD-ROM | disk | FTP | other *** search
/ Aminet 30 / Aminet 30 (1999)(Schatztruhe)[!][Apr 1999].iso / Aminet / comm / maxs / mp2.lha / C / SupportUtil.Text < prev    next >
Text File  |  1997-11-09  |  5KB  |  227 lines

  1.  
  2.             /X\2 CGI support pack
  3.             ~~~~~~~~~~~~~~~~~~~~~
  4.  
  5. All these commands should go in BBS:c/ for best use.
  6.  
  7. The commands are:-
  8.  
  9. AddKey        - Adds a string of keypresses to the input chain
  10. AddNum        - Simple number adding like ADD in amos.
  11. CursPos        - Lets you specify a cursor position in ansi files
  12. DumpHour    - Returns which hour of the day it is (0-23)
  13. DumpHourQuarter    - Returns which quarter of the day it is (0-3)
  14. DumpMsgData    - Returns information about message being written
  15. DumpUserData    - Dump User Data - latest version.
  16. FidoCarasoul    - An example script from my own collection.
  17. IncNum        - Add a number to a variable
  18. Locate        - Locates the cursor on screen
  19. oEcho        - Echo replacement.  Changes 0's to o's
  20. SectionHour.Script - A script to show you how to change menu ansi's on the hour.
  21. SubNum        - Subtract a number from a variable
  22.  
  23.  
  24. In more detail
  25. ~~~~~~~~~~~~~~
  26.  
  27. AddKey
  28. ~~~~~~
  29.  
  30. Params:  Node "Message"
  31.  
  32. Node is the node number you wish to send the strig to.  "Message" is a set of
  33. keypresses that you wish to fake.
  34.  
  35. eg.  AddKey 1 "S"
  36.  
  37.  
  38.  
  39. AddNum
  40. ~~~~~~
  41.  
  42. Params:  Variable Amount Min Max
  43.  
  44. Adds amount to a variable.  If the number should pass MAX then it is reset
  45. to MIN.  If no variable exists, it is created automatically with amount MIN.
  46.  
  47. eg.  AddNum Counter 1 0 9999
  48.  
  49.  
  50.  
  51. CursPos
  52. ~~~~~~~
  53.  
  54. Params:  Filename X-pos Y-pos
  55.  
  56. Places a cursor position code on the end of FILENAME.  Do *NOT* edit this
  57. script in a text ed that doesn't preserve escape codes!!!!!!
  58.  
  59. eg.  CursPos Menu.ansi 10 15
  60.  
  61.  
  62.  
  63. DumpHour
  64. ~~~~~~~~
  65.  
  66. Params:  None
  67.  
  68. This returns the current hour of the day in its output.  You will need to
  69. redirect this to be useful.  All results will be 0-23.
  70.  
  71. eg.  DumpHour >Hour
  72.  
  73.  
  74.  
  75. DumpHourQuarter
  76. ~~~~~~~~~~~~~~~
  77.  
  78. Params:  None
  79.  
  80. This is similiar to DumpHour, but returns which 6 hour period of the day it
  81. is.  Returns 0-3.
  82.  
  83. e.g. DumpHourQuarter >HourQuarter
  84.  
  85.  
  86.  
  87. DumpMsgData
  88. ~~~~~~~~~~~
  89.  
  90. Params:  Node
  91.  
  92. This fills 3 ENV variables with information about the current message being
  93. written/read.
  94.  
  95. MPMsgFrom?
  96. MPMsgTo?
  97. MPMsgSubject?
  98.  
  99. (?'s are the node number, like dump user data)
  100.  
  101.  
  102. eg.  DumpMsgData 1
  103.  
  104.  
  105.  
  106. DumpUserData
  107. ~~~~~~~~~~~~
  108.  
  109. Fully working version of this util.  Refer to /X\2 dox for more info.
  110.  
  111.  
  112.  
  113. FidoCarasoul
  114. ~~~~~~~~~~~~
  115.  
  116. This is an example carasoul script from my own system.   I have a dir called
  117. FidoANSI, containing 6 ansi's labeled 0-5.
  118.  
  119. This script is run INSTEAD of displaying an ansi in a max's text line &
  120. it returns the right ansi to be displayed by /X\2 :)
  121.  
  122. E.g.  %"BBS:C/FidoCarasoul"  
  123.  
  124.  
  125.  
  126. IncNum
  127. ~~~~~~
  128.  
  129. Params:  Variable Amount
  130.  
  131. Similiar to AddNum, except it does not handle min or max amounts.
  132.  
  133. e.g. IncNum Counter 1
  134.  
  135.  
  136.  
  137. Locate
  138. ~~~~~~
  139.  
  140. Params:  X-pos  Y-pos
  141.  
  142. This simply places the cursor on the current screen.  To be used mainly for
  143. filebase scripts.
  144.  
  145. eg.  Locate 10 15
  146.  
  147.  
  148.  
  149. oEcho
  150. ~~~~~
  151.  
  152. Params: Text
  153.  
  154. This is a cut down Echo command for 1 line text files only.  It replaces
  155. 0's with o's and that's the only real difference!
  156.  
  157. eg.  oEcho "You have access 10,000!"
  158.  
  159. returns:  You have access 1o,ooo!
  160.  
  161.  
  162.  
  163. SectionHour.Script
  164. ~~~~~~~~~~~~~~~~~~
  165.  
  166. Params:  Menu_Name
  167.  
  168. A complicated script that will display a menu ansi depending on the time of 
  169. day!.  It assumes that you refer to your menus by MENU:
  170.  
  171. In a directory MENU_NAME, you have 4 main ansi files called Hour0 - Hour3.
  172.  
  173. These 4 ansi's handle the quarter hour of the day.  Have 4 identical ansi's
  174. if required.  These are masters incase one of the hour ansi's are missing.
  175.  
  176. You then just create ansi's named 0-23 to be displayed.  Any missing ones
  177. will display the main 1/4 day ansi.
  178.  
  179.  
  180. e.g. %"bbs:c/SectionHour.Script MainMenu"
  181.  
  182.  
  183.  
  184. SubNum
  185. ~~~~~~
  186.  
  187. Params:  Variable Amount
  188.  
  189. Exactly the same as IncNum, except this subtracts the number from the 
  190. variable.
  191.  
  192. e.g.  SubNum Counter 1
  193.  
  194.  
  195.  
  196. If anyone has any questions, please mail me :)
  197.  
  198. Email: nsa_design@geocities.com
  199.  
  200. FLuFFy NeT:  888:100/0
  201.  
  202. BBS:
  203.  
  204.   .............................................................
  205.   :                                                           :
  206.   :   ____ó\   ____ó\  _____ó\  ____ó\     __   _ó\ _____ó\   :
  207.   :  (÷~___~\ (÷~___/ (óò___÷~\(÷~___~\   //÷) /ó///÷~/ø\ \\  :
  208.   :  /\/ ~ _/ /\/|__\ /\/| / ///\/ ~ _/  /ø / / ///  /\ñ/\ \\ :.............
  209.   : /\ó|\ \\ /ø ó|___/ _ ó/ ø//\ó|\ \\  // /_/ // \\\\   / ø/ :            :
  210.   : \__|/\ \\\___  //\ó__  // \__|/\ \\//___/ ø/   \__\ / //  :   rUN oN   :
  211.   :       \_/    \//     \//        \_/ ~   \//         \_/   :  /X\ 2.00  :
  212.   :...........................................................:            :
  213.           :                                                                :
  214.           :       o-7dAY^cODERS^gFX^mUSIC^aDULTS^fLUFFYnET^aMIGAoNLY!      :
  215.           :                                                                :
  216.           : nODE1 +44 <o>1635 82672o 33K6  ..............................  :
  217.           : nODE2 +44 <o>1635 8272o3 14K4  :                            :  :
  218.           : nODE3 +44 <o>1635 PRIVATE ATM  :   ____ó\   ____ó\   ____ó\ :  :
  219.           :                                :  (öö_~÷÷\ (öö_~÷÷\ (÷~___/ :  :
  220.           : sTAFF:   n!K!  pERK  tECHN!X   :  /\/ /  / /\/ /  /  \/ \   :  :
  221.           :................................: /  |/  \\/  |/  \\ __\óø\  :..:
  222.                                            : \_ó|_  ø/\_ó|_  ø//__~ö//  :
  223.                                            :      \//      \// ~  \//   :
  224.                                            :............................:
  225.  
  226.  
  227.